<?php
namespace Category\Form;

use Zend\Form\Form;
use Zend\Form\Element\Checkbox;

class CategoryForm extends Form
{
    public function __construct($name = null)
    {
	parent::__construct('category');
	$this->setAttributes(array(
	    'method' => 'post',  
	));
	$this->add(array(
	    'name' => 'id',
	    'attributes' => array(
		'type' => 'hidden',
	    ),
	));
	$this->add(array(
	    'name' => 'name',
	    'attributes' => array(
		'type' =>'text',
		'class' => 'form-control',
		'placeholder' => 'Category name..',
	    ),
	    'options' => array(
		'label' => 'Category name',
	    ),
	));
	$this->add(array(
	    'name' => 'alias',
	    'attributes' => array(
		'type' => 'text',
		'class' => 'form-control',
		'placeholder' => 'Alias',
	    ),
	    'options' => array(
		'label' => 'Alias',
	    ),
	));
	$this->add(array(
	    'name' => 'disabled',
	    'type' => 'checkbox',
	    'attributes' => array(
		'type' => 'checkbox',
		'class' => 'checkbox-inline checkbox',
		'id' => 'disable',
	    ),
	));
	$this->add(array(
	    'name' => 'submit',
	    'attributes' => array(
		'type' => 'submit',
		'value' => 'Go',
		'class' => 'btn btn-primary',
	    ),
	));
	
    }
}